<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>

</head>

<body>
    <script>
        const list = [10, 20, 30]
        const res = list.reduce((s, v) => {
            s += v
            return s
        }, 0)
        console.log(res);


        const arr = ['a', 'b', 'c'];
        const html = arr.reduce((s, v) => {
            s + `<li>${v}</li>`;
            return s;
        }, '');

        console.log(html);
    </script>
</body>

</html>